package com.genius.unite_platform.hrm.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.alibaba.fastjson.JSONObject;
import com.genius.adminmanager.other.entity.ResponseJson;
import com.genius.unite_platform.hrm.service.Hrm_jdService;
import com.genius.workflow.log.ControllerLog;

@Controller
public class Hrm_jdSelectController {
	@Autowired
    @Qualifier("hrm_jdSelectService")
    private Hrm_jdService hrmSelectService;
    @RequestMapping("/hrm_jd/toIndex")
    public String toIndex(){
        return "/views/unite_platform/hrm_jd/daoru_dudao";
    }
    @RequestMapping("/hrm_jd/tofendian")
    public String tofendian(){
        return "/views/unite_platform/hrm_jd/daoru_fendian";
    }
    @RequestMapping("/hrm_jd/tozongjian")
    public String tozongjian(){
        return "/views/unite_platform/hrm_jd/daoru_zongjian";
    }
    @RequestMapping("/hrm_jd/tojxsh")
    public String tojxsh(){
        return "/views/unite_platform/hrm_jd/jxsh_select";
    }
    @RequestMapping("/hrm_jd/tojxsh_insert")
    public String tojxsh_insert(){
        return "/views/unite_platform/hrm_jd/jxsh_insert";
    }
    @RequestMapping("/hrm_jd/tojxcx_dudao")
    public String jxcx_dudao(){
        return "/views/unite_platform/hrm_jd/jxcx_dudao";
    }
    @RequestMapping("/hrm_jd/tojxcx_feidudao")
    public String jxcx_feidudao(){
        return "/views/unite_platform/hrm_jd/jxcx_feidudao";
    }
	/**
	 * 跳转到新的查看页面
	 */
	@PostMapping("/hrm_jd/toSearch")
	public String toSearch(){
		return "/views/unite_platform/hrm_jd/jxsh_search";
	}
    @RequestMapping("/hrm_jd/feiyong_select")
    public String feiyong_select(){
        return "/views/unite_platform/hrm_jd/feiyong_select";
    }
    @RequestMapping("/hrm_jd/feiyong_insert")
    public String feiyong(){
        return "/views/unite_platform/hrm_jd/feiyong_insert";
    }
	@PostMapping("/hrm_jd/feiyong_toSearch")
	public String feiyong_toSearch(){
		return "/views/unite_platform/hrm_jd/feiyong_search";
	}
    @RequestMapping("/hrm_jd/feiyong_mendian")
    public String feiyong_mendian(){
        return "/views/unite_platform/hrm_jd/feiyong_mendian";
    }
	/**
	 * 批量导入
	 * @param session
	 * @return
	 * @throws Exception
	 */
	@ControllerLog(description="导入今度督导管店表")
	@PostMapping("/hrm_jd/import_dudao")
	@ResponseBody
	public JSONObject import_dudao(@RequestBody JSONObject json,HttpSession session){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.import_dudao(json, response,session);
		return response;
	}
    /**
     * 查询数据
     * @return
     * @throws Exception
     */
    @ControllerLog(description="查询督导管点表")
    @PostMapping("/hrm_jd/get_dudao")
    @ResponseBody
    public JSONObject get_dudao(@RequestBody JSONObject json){
        JSONObject response = new JSONObject();
        response.put(ResponseJson.code, 0);
        response = hrmSelectService.get_dudao(json, response);
        return response;
    }
	/**
	 * 批量导入
	 * @param session
	 * @return
	 * @throws Exception
	 */
	@ControllerLog(description="导入金虎分店目标")
	@PostMapping("/hrm_jd/import_fendian")
	@ResponseBody
	public JSONObject import_fendian(@RequestBody JSONObject json,HttpSession session){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.import_fendian(json, response,session);
		return response;
	}
	   /**
     * 查询数据
     * @return
     * @throws Exception
     */
    @ControllerLog(description="查询金虎分店目标")
    @PostMapping("/hrm_jd/get_fendian")
    @ResponseBody
    public JSONObject get_fendian(@RequestBody JSONObject json){
        JSONObject response = new JSONObject();
        response.put(ResponseJson.code, 0);
        response = hrmSelectService.get_fendian(json, response);
        return response;
    }
    /**
	 * 批量导入
	 * @param session
	 * @return
	 * @throws Exception
	 */
	@ControllerLog(description="导入金虎分店目标")
	@PostMapping("/hrm_jd/import_zongjian")
	@ResponseBody
	public JSONObject import_zongjian(@RequestBody JSONObject json,HttpSession session){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.import_zongjian(json, response,session);
		return response;
	}
	/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询金虎分店目标")
	 @PostMapping("/hrm_jd/get_zongjian")
	 @ResponseBody
	 public JSONObject get_zongjian(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.get_zongjian(json, response);
	     return response;
	 }
	/**
	 * 新增填充操作
	 */
	@PostMapping("/hrm_jd/fillAdd")
	@ResponseBody
	public JSONObject fillAdd(@RequestBody JSONObject json){
	
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.fillAdd(json, response);
		return response;
	}
	/**
	 * 编辑填充操作
	 */
	@PostMapping("/hrm_jd/fillEdit")
	@ResponseBody
	public JSONObject fillEdit(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.fillEdit(json, response);
		return response;
	}
	/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询今度分店目标")
	 @PostMapping("/hrm_jd/getSelectBody")
	 @ResponseBody
	 public JSONObject getSelectBody(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.getSelectBody(json, response);
	     return response;
	 }
		/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询")
	 @PostMapping("/hrm_jd/getperformance")
	 @ResponseBody
	 public JSONObject getperformance(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.getperformance(json, response);
	     return response;
	 }
	/**
	 * 添加操作
	 * @param session
	 * @return
	 * @throws Exception
	 */
	@ControllerLog(description="添加信息")
	@PostMapping("/hrm_jd/add")
	@ResponseBody
	public JSONObject dictadd(@RequestBody JSONObject json,HttpSession session){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.add(json, response,session);
		return response;
	}
		/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询")
	 @PostMapping("/hrm_jd/getsearch")
	 @ResponseBody
	 public JSONObject getsearch(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.getsearch(json, response);
	     return response;
	 }
		/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询今度分店目标")
	 @PostMapping("/hrm_jd/feiyong_getSelectBody")
	 @ResponseBody
	 public JSONObject feiyong_getSelectBody(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.feiyong_getSelectBody(json, response);
	     return response;
	 }
	/**
	 * 添加操作
	 * @param session
	 * @return
	 * @throws Exception
	 */
	@ControllerLog(description="添加信息")
	@PostMapping("/hrm_jd/feiyong_add")
	@ResponseBody
	public JSONObject feiyong_add(@RequestBody JSONObject json,HttpSession session){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.feiyong_add(json, response,session);
		return response;
	}
		/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询")
	 @PostMapping("/hrm_jd/feiyong_getperformance")
	 @ResponseBody
	 public JSONObject feiyong_getperformance(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.feiyong_getperformance(json, response);
	     return response;
	 }
		/**
		 * 编辑填充操作
		 */
		@PostMapping("/hrm_jd/feiyong_fillEdit")
		@ResponseBody
		public JSONObject feiyong_fillEdit(@RequestBody JSONObject json){
			JSONObject response = new JSONObject();
	    	response.put(ResponseJson.code, 0);
	    	response = hrmSelectService.feiyong_fillEdit(json, response);
			return response;
		}
		/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询金虎分店目标")
	 @PostMapping("/hrm_jd/feiyong_getBody")
	 @ResponseBody
	 public JSONObject feiyong_getBody(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.feiyong_getBody(json, response);
	     return response;
	 }
	/**
	 * 新增填充操作
	 */
	@PostMapping("/hrm_jd/feiyong_fillAdd")
	@ResponseBody
	public JSONObject feiyong_fillAdd(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.feiyong_fillAdd(json, response);
		return response;
	}
	/**
	 * 删除操作
	 */
	@ControllerLog(description="删除绩效")
	@PostMapping("/hrm_jd/feiyong_batchdel")
	@ResponseBody
	public JSONObject batchdel(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	hrmSelectService.feiyong_batchdel(json, response);
		return response;
	}
	/**
	 * 审核
	 */
	@ControllerLog(description="审核绩效")
	@PostMapping("/hrm_jd/feiyong_toshenhe")
	@ResponseBody
	public JSONObject feiyong_toshenhe(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	hrmSelectService.feiyong_toshenhe(json, response);
		return response;
	}
	/**
	 * 审核
	 */
	@ControllerLog(description="作废绩效")
	@PostMapping("/hrm_jd/feiyong_tozuofei")
	@ResponseBody
	public JSONObject feiyong_tozuofei(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	hrmSelectService.feiyong_tozuofei(json, response);
		return response;
	} 
	/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询")
	 @PostMapping("/hrm_jd/feiyong_getsearch")
	 @ResponseBody
	 public JSONObject feiyong_getsearch(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.feiyong_getsearch(json, response);
	     return response;
	 }
	/**
	 * 导出操作
	 */
	@ControllerLog(description="导出")
	@PostMapping("/hrm_jd/feiyong_exportExcel")
	@ResponseBody
	public JSONObject feiyong_exportExcel(HttpServletRequest request,HttpServletResponse responseServlet){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.feiyong_exportExcel(request, responseServlet, response);
		return response;
	}
	/**
	 * 导出操作
	 */
	@ControllerLog(description="导出")
	@PostMapping("/hrm_jd/mendian_exportExcel")
	@ResponseBody
	public JSONObject mendian_exportExcel(HttpServletRequest request,HttpServletResponse responseServlet){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.mendian_exportExcel(request, responseServlet, response);
		return response;
	}
		/**
	  * 查询数据
	  * @return
	  * @throws Exception
	  */
	 @ControllerLog(description="查询金虎分店目标")
	 @PostMapping("/hrm_jd/getBody")
	 @ResponseBody
	 public JSONObject getBody(@RequestBody JSONObject json){
	     JSONObject response = new JSONObject();
	     response.put(ResponseJson.code, 0);
	     response = hrmSelectService.getBody(json, response);
	     return response;
	 }
	/**
	 * 导出操作
	 */
	@ControllerLog(description="导出督导绩效")
	@PostMapping("/hrm_jd/dudao_exportExcel")
	public JSONObject dudao_exportExcel(HttpServletRequest request,HttpServletResponse responseServlet){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.dudao_exportExcel(request, responseServlet, response);
		return response;
	}
	/**
	 * 导出操作
	 */
	@ControllerLog(description="导出非督导绩效")
	@PostMapping("/hrm_jd/feidudao_exportExcel")
	public JSONObject feidudao_exportExcel(HttpServletRequest request,HttpServletResponse responseServlet){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	response = hrmSelectService.feidudao_exportExcel(request, responseServlet, response);
		return response;
	}
	/**
	 * 审核
	 */
	@ControllerLog(description="审核绩效")
	@PostMapping("/hrm_jd/toshenhe")
	@ResponseBody
	public JSONObject toshenhe(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	hrmSelectService.toshenhe(json, response);
		return response;
	}
	/**
	 * 删除操作
	 */
	@ControllerLog(description="删除绩效")
	@PostMapping("/hrm_jd/batchdel")
	@ResponseBody
	public JSONObject batchdel1(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	hrmSelectService.batchdel(json, response);
		return response;
	}
	/**
	 * 审核
	 */
	@ControllerLog(description="作废绩效")
	@PostMapping("/hrm_jd/tozuofei")
	@ResponseBody
	public JSONObject tozuofei(@RequestBody JSONObject json){
		JSONObject response = new JSONObject();
    	response.put(ResponseJson.code, 0);
    	hrmSelectService.tozuofei(json, response);
		return response;
	} 
}
